import { getStorageKey, localStorage, StorageKeyType } from "./component/localStorage.js"
import LocalOldOrderList from './pendingOrder.json' with { type: "json" }

import { getOrderId } from "./component/util.js"

async function log() {
    for (const order of LocalOldOrderList) {
        const orderId = await getOrderId(order.code)
        const storageKey = getStorageKey(orderId, StorageKeyType.mainStatus)
        const status = localStorage.getItem(storageKey)
        console.log(`${order.code} ${orderId} status: ${status}`)
    }
}

await log()